<?php
include_once('./header.php');
?>
				<div id="corps-grand">
					<div id="tete-corps-grand"></div>
					<div id="milieu-corps-grand">
						<?php
						//les temps d'appartenance a l'unite pour "la periode de teste/recrutement"
						//en gros on aura les nouveau joueur et le temps depuis lequel ils ont été recruter + le temp de jeu‏
						/*
						
						$page = "http://census.soe.com/get/ps2:v2/character/?name.first_lower=";
							$census=file_get_contents($page.$nom);

							$parsed_json = json_decode($census);
						*/				
						
						$id_perso = '5428186359685127617'; //id personage
						$page = 'http://census.soe.com/get/ps2:v2/character/?character_id='.$id_perso.'&c:resolve=item_full(name.fr,description.fr,image_id)';
						$census=file_get_contents($page);
						$parsed_json = json_decode($census,true);
						//var_dump($parsed_json);
						array_pop($parsed_json);
						//var_dump(array_pop($parsed_json));
						$i = 0;

						foreach($parsed_json as $characters) {
							foreach($characters as $character) {
								$nom = $character['name'];
								$rang = $character['battle_rank'];
								$certs = $character['certs'];
								$charId = $character['character_id'];
								$rubansJournalier = $character['daily_ribbon'];
								$factionId = $character['faction_id'];
								$teteId = $character['head_id'];
								$items = $character['items'];
								$profileId = $character['profile_id'];
								$infoTemps = $character['times'];
								$titreID = $character['title_id'];

								//echo $nom['first'].'<br><br>';
							}
							foreach($items as $item) {
								echo '<img title="' . $item['name']['fr'] . '" src="https://census.soe.com/files/ps2/images/static/' . $item['image_id'] . '.png" style="height:64px;" alt="' . $item['name']['fr'] . '" /><br>' . $item['description']['fr'] . '<br><br>';
							}
						}
						?>
					</div>
					<div id="pied-corps-grand"></div>
				</div>
				<br class="clear" /> 
<?php
include_once('./footer.php');
?>